/*
 * This source code is part of TWaver 4.0
 *
 * Serva Software PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
 * Copyright 2002 - 2011 Serva Software. All rights reserved.
 */

package demo.editor.chassis;

import twaver.Card;
import twaver.Port;
import twaver.Rack;
import twaver.Shelf;
import twaver.Slot;
import twaver.TUIManager;
import twaver.TWaverUtil;
import twaver.network.TNetwork;
import twaver.network.toolbar.BaseNetworkDnDButton;

public class EquipmentButton extends BaseNetworkDnDButton{
    
	public static class RackButton extends EquipmentButton{
		public RackButton(TNetwork network) {
			super(Rack.class, network);
		}
	}
	public static class ShelfButton extends EquipmentButton{
		public ShelfButton(TNetwork network) {
			super(Shelf.class, network);
		}
	}
	public static class SlotButton extends EquipmentButton{
		public SlotButton(TNetwork network) {
			super(Slot .class, network);
		}
	}
	public static class CardButton extends EquipmentButton{
		public CardButton(TNetwork network) {
			super(Card.class, network);
		}
	}
	public static class PortButton extends EquipmentButton{
		public PortButton(TNetwork network) {
			super(Port.class, network);
		}
	}

	public EquipmentButton(Class elementType, TNetwork network){
		super(network, elementType);
		this.setToolTipText(TWaverUtil.getClassNameWithoutPackage(elementType));
		this.setIcon(TUIManager.getIcon(elementType));
	}

}